Add Book to My BookshelfPurchase This Book Online

Chapter 12 - Configuring IP RIP

Cisco & IP Addressing
Louis D. Rossi, Louis R. Rossi and Thomas Rossi
  Copyright © 1999 The McGraw-Hill Companies, Inc.

Chapter 12: Configuring IP RIP
Overview
This discussion only pertains to IP RIP v1.
Routing Information Protocol was defined in 1988, but the protocol had been in use prior to that date. RIP uses hop count as its metric. In the days when links were relatively homogeneous, hop count was an acceptable metric. In recent years, with the advent of widely used WAN links with a varying degree of bandwidth, RIP is less desirable. For instance, if a router could get to a specific network in two different ways and one of those ways was a T1 and the other was a 19200 link, RIP would have no way to distinguish between these two ways if the hop count was the same.
In later chapters we will look at alternatives to IP RIP.
As we discussed earlier, RIP is a distance-vector and classful routing protocol and consequently does not support VLSM. When RIP is used, the IP addressing scheme must be contiguous.
Below is our network topology. We will configure RIP on all routers. Keep in mind that the actual configuration itself is an easy process; the difficult part is to understand the ramifications of the configuration. As an analogy, it only takes a pilot a few minutes to get a 747 airborne, but it takes years of experience to perform such a task successfully. It may only take a few seconds to configure a routing protocol, but it takes a lot longer to completely understand the ramifications of the configuration.
Refer to Figure 12.1 and Table 12.1.
Figure 12.1  Four-Router Topology
Table 12-1  Addresses to be used for Figure 12-1
S0
S1
S2
E0
Router_A
10.10.8.9
N/A
N/A
10.10.1.1
Router_B
10.10.8.1
10.10.12.1
10.10.4.1
N/A
Router_C
10.10.12.9
N/A
N/A
10.10.2.1
Router_D
10.10.4.2
N/A
N/A
10.10.3.1
Mask
255.255.255.0
255.255.255.0
255.255.255.0
255.255.25.0
Configuration Commands
Figure 12.2 shows the commands to configure IP addresses and IP RIP on Router_D.
I have included the IP address configuration lines as a review.
The two IP RIP commands are in bold.
Router_D# config t
Enter configuration commands, one per line.  End with CNTL/Z.
Router_D(config)#int e0
Router_D(config-if)#ip address 10.10.3.1 255.255.255.0
Router_D(config-if)#int s0
Router_D(config-if)#ip address 10.10.4.2 255.255.255.0
Router_D(config-if)#router rip
Router_D(config-router)#network 10.0.0.0
Router_D(config-router)#
Router_D#
%SYS-5-CONFIG_I: Configured from console by console
Router_D#
Figure 12.2  IP RIP Configuration Commands
One of the first questions you might have is why we have not identified both subnets of the Class A address 10.0.0.0.
Remember that IP RIP is a classful routing protocol and therefore does not distinguish subnets of a network. If the address is a Class A, the mask is 255.0.0.0. Because of this fact, we need only to identify the major network.
Verifying Configuration
After Router_D is configured we should verify that our configuration is correct.
The “show run” command will help us verify that we have configured our addresses and the RIP protocol correctly.
Keep in mind that Cisco configuration statements can be truncated, therefore “sh run” is the same as “show running-config”.
Router_D#show running-configuration
Building configuration...
Current configuration:
!
version 11.3
no service password-encryption
!
hostname Router_D
!
interface Ethernet0
  ip address 10.10.3.1 255.255.255.0
!
interface Serial0
  ip address 10.10.4.2 255.255.255.0
  no ip mroute-cache
  no fair-queue
  clockrate 56000
!
interface Serial 1
  no ip address
  shutdown
!
router rip
  network 10.0.0.0
!
ip classless
!
line con 0
line 1 8
line aux 0
line vty 0 4
!
end
Figure 12.3  The “show run” Command
Figure 12.3 shows that the proper addresses are configured on the correct interfaces and RIP will advertise network 10.0.0.0.
By using the command “show ip protocol” (Figure 12.4) we see that RIP is the protocol being used for network 10.0.0.0. We can also determine that Router_D is receiving RIP updates from 10.10.4.1, which is Router_B.
Router_D>show ip protocol
Routing Protocol is "rip"
  Sending updates every 30 seconds, next due in 3 seconds
  Invalid after 180 seconds, hold down 180, flushed after 240
  Outgoing update filter list for all interfaces is not set
  Incoming update filter list for all interfaces is not set
  Redistributing: rip
  Default version control: send version 1, receive any version
    Interface        Send  Recv   Key-chain
    Ethernet0         1    1 2
    Serial0           1    1 2
  Routing for Networks:
    10.0.0.0
  Routing Information Sources:
    Gateway         Distance      Last Update
    10.10.4.1         120          00:00:10
  Distance: (default is 120)
Figure 12.4  The “show ip protocol” Command
Viewing the Routing Table
Once all the routers are configured properly we can view the routing table of Router_D (Figure 12.5).
Router_D#show ip route
Codes: C - connected, S - static, I - IGRP, R - RIP, M - mobile, B - BGP
  D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
  N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
  E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGP
  i - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, * - candidate default
  U - per-user static route, o - ODR
Gateway of last resort is not set
  10.0.0.0/24 is subnetted, 6 subnets
R    10.10.1.0 [120/2] via 10.10.4.1, 00:00:25, Serial0
R    10.10.2.0 [120/2] via 10.10.4.1, 00:00:25, Serial0
C    10.10.3.0 is directly connected, Ethernet0
C    10.10.4.0 is directly connected, Serial0
R    10.10.8.0 [120/1] via 10.10.4.1, 00:00:25, Serial0
R    10.10.12.0 [120/1] via 10.10.4.1, 00:00:25, Serial0
Router_D#
Figure 12.5  The “show ip route” Command
Notice we have 6 routes. Two of these are connected to Router_D and are prefixed with a “C”. Four routes are discovered through the RIP process; these are prefixed with an “R”.
Because our address design is contiguous, the subnets of network 10.0.0.0 are communicated to its neighbors.
120 is the default administrative distance for IP RIP. The number that follows the administrative distance is the hop count to that network.
Reviewing the routing table, we see that it will take Router_D 2 hops to get to network 10.10.1.0.
There very often is confusion as to what actually is a hop. Think of it in this way; if a packet must go through a router to get to the destination, it is considered a hop.
In our example, Host A is 3 hops away from Host B, but Router_D is only 2 hops away from Network 10.10.1.0, since Router_D is not considered a hop.
I have only shown configuration for Router_D; to complete the configuration of the topology in Figure 12.1 all of the routers would be configured in the same manner.
In Figure 12.6 I have included, for your information, the additional configuration line for RIP v2.
RIP v2 is a classless routing protocol and therefore works in a very different way than RIP v1.
Router(config-router)#router rip
Router(config-router)#version 2
Router(config-router)#network 10.0.0.0
Router(config-router)#
Figure 12.6  Configuration of IP RIP Version 2
Configuring a Static Route
As we said in Chapter 5 there are times you may want to configure a static route. Please refer to Figure 12.7.
router_b(config)#ip route 10.10.10.5 ?
  A.B.C.D  Destination prefix mask
router_b(config)#ip route 10.10.10.5 255.255.255.0 ?
  A.B.C.D    Forwarding router’s address
  BRI        ISDN Basic Rate Interface
  Null       Null interface
  Serial     Serial
  TokenRing  IEEE 802.5
router_b(config)#ip route 10.10.10.0 255.255.255.0 serial 0
router_b(config)#
Figure 12.7  Configuring a Static Route
Figure 12.7 illustrates that router_b should forward all IP packets with the destination subnet of 10.10.10.0 to its own Serial 0 interface. We also could have configured the next hop address.
When configuring a static route by using an interface, as was done in Figure 12.7, the static route will appear as a directly connected network (Figure 12.8).
router_b#sh ip route
Codes: C - connected, S - static, I - IGRP, R - RIP, M - mobile, B - BGP
  D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
  N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
  E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGP
  i - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, * - candidate default
  U - per-user static route, o - ODR
Gateway of last resort is not set
  172.16.0.0/30 is subnetted, 1 subnets
C    172.16.7.4 is directly connected, Serial0
  10.0.0.0/24 is subnetted, 1 subnets
S     10.10.10.0 is directly connected, Serial0
Figure 12.8  Verifying a Static Route
Configuring a Default Route
When a default route is configured, the router will not send packets to the bit bucket when the destination route does not appear in the routing table. The packets will be sent to the default route. Refer to Figure 12.9.
router_b(config)#ip default-network 172.17.0.0
router_b(config)#^Z
router_b#
%SYS-5-CONFIG_I: Configured from console by console
router_b#sh ip route
Codes: C - connected, S - static, I - IGRP, R - RIP, M - mobile, B - BGP
  D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
  N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
  E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGP
  i - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, * - candidate default
  U - per-user static route, o - ODR
Gateway of last resort is 172.16.7.6 to network 172.17.0.0
R*    172.17.0.0/16 [120/1] via 172.16.7.6, 00:00:04, Serial0
  172.16.0.0/30 is subnetted, 1 subnets
C    172.16.7.4 is directly connected, Serial0
  10.0.0.0/24 is subnetted, 1 subnets
S    10.10.10.0 is directly connected, Serial0
Figure 12.9  Configuring and Verifying a Default Route
Figure 12.9 illustrates that all packets whose destination address is not listed in the routing table will be sent to network 172.17.0.0, the gateway of last resort. The next-hop address is 172.16.7.6.

 


 
Books24x7.com, Inc © 2000 –  Feedback